package com.ruoyi.kanban.domain;

import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

/**
 * 流水号记录对象 kb_sequence_number
 * 
 * @author ruoyi
 * @date 2025-01-15
 */
public class SequenceNumber extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 主键ID */
    private Long id;

    /** 版本号，用于乐观锁 */
    @Excel(name = "版本号")
    private Integer version;

    /** 流水号的key */
    @Excel(name = "流水号key")
    private String seqKey;

    /** 当前序列号 */
    @Excel(name = "当前序列号")
    private Long seq;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }
    public void setVersion(Integer version) 
    {
        this.version = version;
    }

    public Integer getVersion() 
    {
        return version;
    }
    public void setSeqKey(String seqKey) 
    {
        this.seqKey = seqKey;
    }

    public String getSeqKey() 
    {
        return seqKey;
    }
    public void setSeq(Long seq) 
    {
        this.seq = seq;
    }

    public Long getSeq() 
    {
        return seq;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("version", getVersion())
            .append("seqKey", getSeqKey())
            .append("seq", getSeq())
            .append("createTime", getCreateTime())
            .append("updateTime", getUpdateTime())
            .toString();
    }
}